package com.getech.smc.demo1.controller;

import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

/**
 * @authore zyx
 * @date 2018/8/1 10:26
 */
@RestController
@Slf4j
@RequestMapping("/")
public class TestController {

    @RequestMapping(value = "/test/{id}", method = RequestMethod.GET)
    public String test(@PathVariable("id") String id){
        log.info("I from " + id);
        return "I from " + id;
    }
}
